package com.gthncz;

import org.springframework.context.support.AbstractApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import com.gthncz.beans.TextEditor;

public class DIDemo {
	
	public static void main(String[] args) {
		@SuppressWarnings("resource")
		AbstractApplicationContext context = new ClassPathXmlApplicationContext("Beans_autowire.xml"); // Beans_DI.xml
		TextEditor textEditor = (TextEditor) context.getBean("textEditor");
		textEditor.autoComplete();
		textEditor.spellCheck();
		context.registerShutdownHook();
	}
	
}
